package com.example.list;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;

import com.haibin.calendarview.CalendarLayout;
import com.haibin.calendarview.CalendarView;

public class CalendarActivity extends AppCompatActivity {

    private CalendarView calendarView;
    private CalendarLayout calendarLayout;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_calendar);

        calendarView = (CalendarView) findViewById(R.id.calendarView);
        calendarLayout = (CalendarLayout) findViewById(R.id.calendar_layout);
        calendarLayout.setModeOnlyMonthView();
        calendarLayout.showCalendarView();

        calendarView.setWeekStarWithSun();

        calendarView.setRange(2021,1,1,
                              2021,3,31);

    }
}